<!--#include file="../inc/const.asp"-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><%=webname%></title>
<meta name="keywords" content="<%=indexkeywords%>" />
<meta name="description" content="<%=indexdescription%>" />
<style type="text/css">
body{font-family:"宋体"; font-size:14px}
</style>
</head>
<body>
<%
Sub viewList(id)
dim sql,rs
	sql = "select [ID],[Title] From [{pre}Content] where [Cid]="&id&" "
	set rs = db(sql,1)
	do while not rs.eof
	response.Write "<div style='height:25px; line-height:25px'><a href='index.asp?act=content&id="&rs("ID")&"'>"&rs("Title")&"</a></div>"
	rs.movenext
	loop
End Sub

Sub viewContent(id)
dim sql,rs
	sql = "select [CID],[content] From [{pre}Content_01] where [Aid]="&id&" "
	set rs = db(sql,1)
	do while not rs.eof
	response.Write "<div style='line-height:25px'>"&rs("content")&"</div>"
	rs.movenext
	loop
End Sub
'# 列表
Sub ListChannelX(x)
	'Ns(0,i) Ns(1,i)    Ns(2,i)   Ns(3,i)    Ns(4,i)  Ns(5,i)   Ns(6,i)  Ns(7,i) Ns(8,i)
	'[ID]    [FatherID] [ClildID] [DeepPath] [Name]   [Order]   [Domain] [Table] [OutSideLink]
 	Dim tID
	Dim tFatherID
	Dim tChildID
	Dim tDeepPath
	Dim tName
	Dim tOrder
	Dim tDomain
	Dim tStyle
 	Dim tTable
	Dim tOutSideLink
	Dim tDisplay
	dim ns,sql,rs
	Sql = "Select [ID],[FatherID],[ChildID],[DeepPath],[Name],[Order],[Domain],[Table],[OutSideLink],[Display] From [{pre}Channel] where [FatherID]="&x&" and [OutSideLink]=0"
	Set Rs = DB(Sql,1)
	Dim i,j
	do while not rs.eof	
	if rs("FatherID")=0 then
	response.Write "<div style='height:25px; line-height:25px;background:#0066FF; font-weight:bold;color:#fff; padding-left:5px;'>"&rs("Name")&"</Div>"&vbcrlf
	else
	response.Write "<div style='height:25px; line-height:25px; padding-left:10px;'> |-<a href='index.asp?act=view&id="&rs("ID")&"'>"&rs("name")&"</a></div>"&vbcrlf
	end if
	ListChannelX(rs("ID"))
	%>
<%
				
				'ListChannelX Rs(0) '该ID下的分类
				rs.movenext
	loop
End Sub
%>
<%
Dim ID
ID = Request("id")
if Not IsNumeric(ID) Or Instr(ID,",")>0 Then Response.write "参数错误":response.End()
select case request("act")
case "view"
	Call viewList(id)
case "content"
	call viewContent(id)
case ""
	call ListChannelX(0)
end select
%>
<%
if Len(request("act"))>0 Then
%>
<div style="text-align:right; padding:0 10px 5px 0"><button onclick="history.back();" style="border:1px solid #CCCCCC">返 回</button></div>
<%
End If
%>
<div style="border-top:1px solid #CCCCCC; line-height:25px; height:25px; color:#666666">Powered by 5u.hk! v3</div>
</body>
</html>
